#ifndef __INSTRUCTIONPARSER__
#define __INSTRUCTIONPARSER__

#include "instructiontable.h"
#include "shared.h"
#include "errorhandler.h"
#include "symboltable.h"
#include "registertable.h"
#include "lexer.h"
//语法分析器，两次扫描分析语法
ERROR parse(const vector<InstructionParseEntry>& instructionParseList);

ERROR translateInstruction(const string& instruction, const vector<string>& operands, map<string, SymbolTableEntry>& symbolTable, ofstream& outputFile);

ERROR second_parse(const vector<InstructionParseEntry>& instructionParseList,string outputFileName);
#endif